<h1>Listing businesses</h1>

<table>
  <tr>
    <th>Overall rating</th>
    <th>Price rating</th>
    <th>Type</th>
    <th>Website url</th>
    <th>Street1</th>
    <th>Street2</th>
    <th>Neigbourhood</th>
    <th>City</th>
    <th>State</th>
    <th>Zip code</th>
    <th>Number of overal ratings</th>
    <th>Number of price ratings</th>
  </tr>

<% for business in @businesses %>
  <tr>
    <td><%=h business.overall_rating %></td>
    <td><%=h business.price_rating %></td>
    <td><%=h business.type %></td>
    <td><%=h business.website_url %></td>
    <td><%=h business.street1 %></td>
    <td><%=h business.street2 %></td>
    <td><%=h business.neigbourhood %></td>
    <td><%=h business.city %></td>
    <td><%=h business.state %></td>
    <td><%=h business.zip_code %></td>
    <td><%=h business.number_of_overal_ratings %></td>
    <td><%=h business.number_of_price_ratings %></td>
    <td><%= link_to 'Show', business %></td>
    <td><%= link_to 'Edit', edit_business_path(business) %></td>
    <td><%= link_to 'Destroy', business, :confirm => 'Are you sure?', :method => :delete %></td>
  </tr>
<% end %>
</table>

<br />

<%= link_to 'New business', new_business_path %>
